function y=cummean(x)
% calculate the recursive (cumulative) mean for each column

ix = ones(size(x));
y = cumsum(x)./cumsum(ix);
